package my.suveng.oauth2.model.dto;

import lombok.Data;

import javax.validation.constraints.Email;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Pattern;

/**
 * 注册参数
 *
 * @author suwenguang
 **/
@Data
public class RegisterDto {
    @Email
    @NotNull
    private String email;

    @NotNull
    private String code;

    @NotBlank
    @Pattern(regexp = "[0-9a-zA-Z._+/.!@#$%^&*()~<>,?{}]+")
    private String password;

    @NotBlank
    @Pattern(regexp = "[0-9a-zA-Z._+/.!@#$%^&*()~<>,?{}]+")
    private String repeatPassword;
}
